package edu.zju.gis.cky.entity.dto;

import edu.zju.gis.cky.entity.Meta;
import lombok.Data;

import java.util.Date;

@Data
public class UpdateDTO {

    private Long id;

    private String depart;

    private String regionNumber;

    private String region;

    private String coordinate;

    private String elevation;

    private String source;

    private Date produceTime;

    private String temporal;

    private String resolution;

    private String sensor;

    private String secret;

    private String description;

    private String other;

    public Meta toMeta() {
        Meta meta = new Meta();
        meta.setId(id);
        meta.setDepart(depart);
        meta.setRegionNumber(regionNumber);
        meta.setRegion(region);
        meta.setCoordinate(coordinate);
        meta.setElevation(elevation);
        meta.setSource(source);
        meta.setProduceTime(produceTime);
        meta.setTemporal(temporal);
        meta.setResolution(resolution);
        meta.setSensor(sensor);
        meta.setSecret(secret);
        meta.setDescription(description);
        meta.setOther(other);
        return meta;
    }

}
